import sys

i = 2
if len(sys.argv) < 2:
    exit(1)
f = open(sys.argv[1], "wb")
if f.seekable() == False:
    exit(1)
f.write(0x100000 * b'\0')
while i + 1 < len(sys.argv):
    with open(sys.argv[i + 1], "rb") as infile:
        f.seek(int(sys.argv[i]) * 0x200)
        content = infile.read()
        f.write(content)
    i += 2

